import request from "@/utils/request";

export function addDept(data) {
  return request({
    url: "/system/dept",
    method: "post",
    data: data,
  });
}

export function mainlist(query) {
  return request({
    url: "/system/main/list",
    method: "get",
    params: query,
  });
}
export function mainDel(id) {
  return request({
    url: "/system/main/" + id,
    method: "delete",
  });
}
// 督办
export function supervising(query) {
  return request({
    url: "/system/main/supervising/" + query,
    method: "get",
  });
}

export function listNoAuth(query) {
  return request({
    url: "/system/user/listNoAuth",
    method: "get",
    params: query,
  });
}
export function mainAdd(query) {
  return request({
    url: "/system/main",
    method: "post",
    data: query,
  });
}
export function mainUpdate(query) {
  return request({
    url: "/system/main",
    method: "put",
    data: query,
  });
}

/*  诉求处理-受理*/
export function addAccept(query) {
  return request({
    url: "/system/main/accept",
    method: "put",
    data: query,
  });
}
/* 诉求处理-删除 */
export function DelAccept(id) {
  return request({
    url: "/system/main/" + id,
    method: "delete",
  });
}
/* 诉求处理-详情 */
export function getAccept(id) {
  return request({
    url: "/system/main/" + id,
    method: "get",
  });
}
/* 案件处理-处理 */
export function addDispose(query) {
  return request({
    url: "/system/main/dispose",
    method: "put",
    data: query,
  });
}
/* 补充资料 */
export function addBczl(data) {
  return request({
    url: "/system/bczl",
    method: "post",
    data: data,
  });
}
/* 回访接口 */
export function addDisposereturn(query) {
  return request({
    url: "/system/main/disposereturn",
    method: "put",
    data: query,
  });
}
export function recentTrend(id) {
  return request({
    url: '/system/main/recentTrend',
    method: 'get',
  })
}
export function mainseeYear(id) {
  return request({
    url: '/system/main/seeYear/2025',
    method: 'get',
  })
}

export function handleAnalytics(id) {
  return request({
    url: '/system/main/handleAnalytics',
    method: 'get',
  })
}
/* 查询所有部门 */
  export function listNotAuth(query) {
    return request({
      url: "/system/dept/listNotAuth",
      method: "get",
      params: query,
    });
  }
/* 首页-案件日统计量 */
export function seeDaydate(query) {
  return request({
    url: "/system/main/seeDay/"+query,
    method: "get",
  });
}
/* 首页-案件月统计量 */
export function seeMonthdate(query) {
  return request({
    url: "/system/main/casesDispose",
    method: "get",
  });
}
export function listOrderByDiff(query) {
  return request({
    url: "/system/main/listOrderByDiff",
    method: "get",
    params: query
  });
}
